#include"calClient.hpp"
#include<memory>
static void Usage(string proc)
{
    cout<<"\nUsage:\n\t"<<proc<<" serverip serverport\n\n";
}
int main(int argc,char* argv[])
{
    if(argc!=3)//./tcpClient  ip 8080
    {
        Usage(argv[0]);
    }
    string ip = argv[1];
    uint16_t port = atoi(argv[2]);//端口号通常占用 2 字节（16位)
    unique_ptr<TcpClient> tcli(new TcpClient(ip,port));

    tcli->initClient();
    tcli->start();
    

    return 0;
}